﻿using System;
using System.Diagnostics;

namespace iPhoneUI.Commands
{
    public class NavigationCmdLet : ICmdLet
    {
        public NavigationCmdLet()
        {
        }

        public string Page { get; set; }

        public IWidgetOwner Owner { get; set; }

        public bool IsValid
        {
            get
            {
                return true;
            }
        }

        public void Execute()
        {
            Debug.Assert(Owner != null);
            Owner.GotoPage(Page);
        }
    }
}
